/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package com.persistencia.domain;

import java.io.Serializable;
import javax.persistence.Basic;
import javax.persistence.Column;
import javax.persistence.Embeddable;
import javax.validation.constraints.NotNull;

/**
 *
 * @author kenny
 */
@Embeddable
public class ClasexclasePK implements Serializable {
    @Basic(optional = false)
    @NotNull
    @Column(name = "nClsUnoId")
    private int nClsUnoId;
    @Basic(optional = false)
    @NotNull
    @Column(name = "nClsDosId")
    private int nClsDosId;

    public ClasexclasePK() {
    }

    public ClasexclasePK(int nClsUnoId, int nClsDosId) {
        this.nClsUnoId = nClsUnoId;
        this.nClsDosId = nClsDosId;
    }

    public int getNClsUnoId() {
        return nClsUnoId;
    }

    public void setNClsUnoId(int nClsUnoId) {
        this.nClsUnoId = nClsUnoId;
    }

    public int getNClsDosId() {
        return nClsDosId;
    }

    public void setNClsDosId(int nClsDosId) {
        this.nClsDosId = nClsDosId;
    }

    @Override
    public int hashCode() {
        int hash = 0;
        hash += (int) nClsUnoId;
        hash += (int) nClsDosId;
        return hash;
    }

    @Override
    public boolean equals(Object object) {
        // TODO: Warning - this method won't work in the case the id fields are not set
        if (!(object instanceof ClasexclasePK)) {
            return false;
        }
        ClasexclasePK other = (ClasexclasePK) object;
        if (this.nClsUnoId != other.nClsUnoId) {
            return false;
        }
        if (this.nClsDosId != other.nClsDosId) {
            return false;
        }
        return true;
    }

    @Override
    public String toString() {
        return "com.persistencia.domain.ClasexclasePK[ nClsUnoId=" + nClsUnoId + ", nClsDosId=" + nClsDosId + " ]";
    }
    
}
